﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;

namespace wcfServiceLib
{
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the interface name "IService1" in both code and config file together.
    [ServiceContract]
    public interface IService1
    {
        [OperationContract]
        Track GetTrack(int id);

        [OperationContract]
        bool validCredentials(String login, String password);

		[FaultContract(typeof(Wyjatek))]
        [OperationContract]
        User getUser(String name);

		[FaultContract(typeof(Wyjatek))]
        [OperationContract]
        void addTrack(Track track);

		[FaultContract(typeof(Wyjatek))]
        [OperationContract]
        void addPoint(Point point);

		[FaultContract(typeof(Wyjatek))]
        [OperationContract]
        void addRun(Run run);

        [OperationContract]
        List<Run> getRuns(int id);

        [OperationContract]
        List<Track> getTracks(int id);

        [OperationContract]
        List<Point> getPoints(int id);

		[FaultContract(typeof(Wyjatek))]
        [OperationContract]
        void registerUser(User user);

        [OperationContract]
        String getString(int id);
    }


	[DataContract]
	public class Wyjatek
	{
	}
    // Use a data contract as illustrated in the sample below to add composite types to service operations.
    
}
